<!DOCTYPE html>
<html>


<!-- Mirrored from webapplayers.com/inspinia_admin-v2.3/login.html by HTTrack Website Copier/3.x [XR&CO'2014], Tue, 01 Sep 2015 13:12:22 GMT -->
<head>

    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">

    <title>注册</title>

    <link href="css/bootstrap.min.css" rel="stylesheet">
    <link href="font-awesome/css/font-awesome.css" rel="stylesheet">
    <link href="css/animate.css" rel="stylesheet">
    <link href="css/style.css" rel="stylesheet">

</head>

<body class="gray-bg">

    <div class="middle-box text-center loginscreen animated fadeInDown">
        <div>
            <div>

            </div>
            <form class="m-t" role="form" action="">
                <div class="form-group">
                    <input type="text" class="form-control" placeholder="手机号码" required="" id="name">
                </div>
                <div class="form-group">
                    <input type="password" class="form-control" placeholder="密码" required="" id="pwd">
                </div>
                <button type="button" onclick="login()" class="btn btn-primary block full-width m-b">注册</button>

            </form>
        </div>
    </div>

    <!-- Mainly scripts -->
    <script src="js/jquery-2.1.1.js"></script>
    <script src="js/bootstrap.min.js"></script>
    
    <script type="text/javascript">
    function getQueryString(name) {
		var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
		var r = window.location.search.substr(1).match(reg);
		if (r != null) return unescape(r[2]); return null;
	}
	 
	var openId= getQueryString("id");
	var suffixUrl = "/leo";
	function login(){
		 $.post(suffixUrl + '/user/register', {
 			"mobile": $("#name").val(),
 			"pwd": $("#pwd").val(),
 			"openId": openId,
 		}).always(
 				function(data) {
 					if(data.code == 0){
						window.location.href = "index.html";								
 					}else{
 						alert(data.detail);
 					}
 				}, "json").fail(function() {
 			alert("fail！");
 			return;
 		});
	}
	
    </script>

</body>


<!-- Mirrored from webapplayers.com/inspinia_admin-v2.3/login.html by HTTrack Website Copier/3.x [XR&CO'2014], Tue, 01 Sep 2015 13:12:22 GMT -->
</html>
